<template>
  <div class="app-container">
    <div class="filter-container">
      订单编号：
      <el-input v-model="listQuery.oid" label="订单编号" placeholder="订单编号" style="width: 200px;" class="filter-item mring10"
        @keyup.enter.native="handleFilter" />
      <el-button v-waves class="filter-item" type="primary" icon="el-icon-search" @click="handleFilter" size="small"> 搜索</el-button>
    </div>
    <div class="mixin-components-container">
      <el-row style="text-align:center;margin-top: 180px;">暂无相关记录~</el-row>

    </div>

    <pagination hide-on-single-page v-show="total > 0" :total="total" :page.sync="listQuery.page"
      :limit.sync="listQuery.size" @pagination="getList" />
  </div>
</template>

<script>
import waves from '@/directive/waves' // waves directive
import { parseTime } from '@/utils'
import Pagination from '@/components/Pagination'
import { fetchList,agree,refuse } from '@/api/order/after'

export default {
  name: 'goods',
  components: { Pagination },
  directives: { waves },
  data() {
    return {
      tableKey: '',
      list: [],
      total: 0,
      listLoading: false,
      listQuery: {
        size: 10,
        page: 1,
        name: null,
      },
    }
  },
  created() {
    this.getList()
  },
  methods: {
    getList() {
      this.listLoading = true
      fetchList(this.listQuery).then(response => {
        this.list = response.data.data
        this.total = response.data.total

        // Just to simulate the time of the request
        this.listLoading = false
      })
    },
    handleFilter() {
      this.listQuery.page = 1
      this.getList()
    },
    }
    
}
</script>

<style>
.none {
  display: none;
}

.filter-container{font-size: 12px;}
.mixin-components-container {
  background-color: #fff;
  margin-top: 12px;
  min-height: calc(100vh - 84px);
  padding: 18px 10px;
  ;
  font-size: 12px;
}

.component-item {
  min-height: 100px;
}

.filter-container {
  padding: 8px 15px;
  background: #fff;
}

.order-table {
  padding-top: 12px;
  border: none;
  border-collapse: collapse;
}

.order-table tr,
.order-table th,
.order-table td,
.order-table tbody {
  border: none;
  padding: 0;
  margin: 0;
}

.order-th {
  background: #f8f8fa;
  margin-top: 30px;
  overflow: hidden;
  line-height: 38px;
  height: 38px;
  font-size: 14px;
  font-weight: 700;
}

.goods-name {
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  line-height: 18px
}

.title {
  height: 40px;
  line-height: 40px;
  color: #000
}

.title td {
  padding: 10px 15px;
  color: #000
}

.title.bd td {
  border-top: 1px solid #f8f8f8
}

.data-tr td {
  border-right: 1px solid #f8f8f8;
  text-align: center;
  color: #8c8c8c
}

.data-tr td.pic {
  text-align: left
}

.data-tr td.no-border {
  border: 0
}

.no-content td {
  border-bottom: 1px solid #f8f8f8;
  height: 22px;
  line-height: 22px;
}

.filter-container .el-input,
.filter-container .el-select {
  margin-right: 12px;
}
.filter-item input[type='text'] {
  height: 32px;
  line-height: 32px;
  font-size: 12px;
}

.mring10 {
  margin-right: 10px;
}
</style>
